<!-- 左侧列表式模板 -->
<template>
  <div class="template-body">
    <section class="top-nav">
      <firstNav :propsData="propsData" :catList="catList"></firstNav>
    </section>
    <section class="content-box">
      <section class="aside">
        <leftAsideList :propsData="propsData" :catList="catList[0].children"></leftAsideList>
      </section>
      <section class="content">
        <section class="ad">
          <classifyAd :propsData="propsData"></classifyAd>
        </section>
        <section class="goods-section">
          <goodsList :propsData="propsData" :goodsList="catList[0].children[0].goods_list || []"></goodsList>
        </section>
      </section>
    </section>
  </div>
</template>

<script>
import leftAsideList from "../components/leftAsideList/index.vue";
import classifyAd from "../components/classifyAd/index.vue";
import goodsList from "../components/goodsList/index.vue";
import firstNav from "../components/firstNav/index.vue";

export default {
  props: {
    propsData: {
      type: Object,
      default: {},
    },
    catList:{
      type: Array,
      default: () => {
        return []
      },
    }
  },
  mixins: [],
  components: { leftAsideList, classifyAd, goodsList, firstNav },
  data() {
    return {};
  },
  mounted() {},
  watch: {},
  computed: {},
  methods: {},
};
</script>

<style lang="scss" scoped>
.template-body {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  .top-nav {
    width: 100%;
    height: 84px;
    min-height: 84px;
  }
  .content-box {
    padding-top: 6px;
    flex: auto;
    height: 0;
    display: flex;
    .aside {
      width: 101px;
      min-width: 101px;
      height: 100%;
      background-color: #f2f2f2;
    }
    .content {
      flex: auto;
      height: 100%;
      background: #ffffff;
      overflow-x: hidden;
      overflow-y: scroll;
      .ad {
        padding: 0 1px;
      }
      .goods-section {
        width: 100%;
        // height: 100%;
        padding: 0 16px;
      }
    }
  }
  ::-webkit-scrollbar {
    width: 0;
    height: 0;
  }
}
</style>
